import  req from '../http';


//register页面携带手机号获取验证码
export function getCode(datas){
    return req({
        url:"/api/mbs/member/sentSM?phoneNum="+datas.phone,
        method:"get",
    })
}
//判断账号是否存在F
export function isExists(datas) {
    console.log(datas)
    return  req({
        url: '/api/mbs/member/queryMemberByParam?phoneNum='+datas.phoneNum,
        method: 'get'
    })
}

// 注册register
export function register(datas) {
    console.log(datas)
    return  req({
        url: '/api/mbs/member/insert',
        method: 'post',
        data:datas
    })
}
// 登录
export function login(datas) {
    return req({
        url:'/api/sso/memberLogin/authMember?userName='+datas.userName+'&passWord='+datas.passWord,
        method: 'get' 
    })
}

//修改updatePwd
export function updatePwd(datas) {
    return req({
        url:'/api/mbs/member/pwdback',
        method: 'post',
        data: datas
    })
}
//忘记密码forgetPwd
export function forgetPwd(datas) {
    return req({
        url:'/api/mbs/member/forgetPwd',
        method: 'put',
        data: datas
    })
}
